package love.bot.forli.group.review.entity;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.util.Date;

/**
 * @author Kontori
 */
@Data
@ApiModel(description = "题目实体")
public class Question {

    @ApiModelProperty(value = "题目ID", required = true)
    @TableId(value = "question_id", type = IdType.AUTO)
    private Integer questionId;

    @ApiModelProperty(value = "归属题组ID")
    private Integer questionGroupId;

    @ApiModelProperty(value = "题目类型，0单选1多选2判断")
    private Integer type;

    @ApiModelProperty(value = "题干")
    private String title;

    @ApiModelProperty(value = "正确答案，若多选，以,分隔，若判断，0错1对", example = "0,1,2")
    private String answer;

    @ApiModelProperty(value = "备注（补充）")
    private String remark;

    @ApiModelProperty(value = "分数")
    private Integer score;

    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    private Date createTime;

    @ApiModelProperty(value = "更新时间")
    @TableField(fill = FieldFill.INSERT_UPDATE)
    private Date updateTime;

}
